package com.bjsxt.model;

import com.bjsxt.domain.SysMenu;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.security.core.authority.SimpleGrantedAuthority;

import java.util.List;

/**
 * @date:2022/1/4 9:30
 * @author:yang
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel(value = "用户登录返回结果")
public class LoginResult {
    /**
     * 授权服务器颁发的token
     */
    @ApiModelProperty(value = "授权服务器颁发的token")
    private String token;

    /**
     * 用户的菜单
     */
    @ApiModelProperty(value = "用户的菜单")
    private List<SysMenu> menus;

    /**
     * 用户的权限列表
     */
    @ApiModelProperty(value = "用户的权限列表")
    private List<SimpleGrantedAuthority> authorities;
}
